<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="utf-8" />
	<title>transit</title>
	<style>
	#map_canvas{width:640px;height:400px}
	</style>
	<script src="http://api.map.baidu.com/api?v=1.2"></script>
</head>
<body>
<div id="map_canvas"></div>
<script>
var map = new BMap.Map('map_canvas');
map.centerAndZoom(new BMap.Point(116.404, 39.915), 12);

var transit = new BMap.TransitRoute('北京', {
    renderOptions: {
        map: map
    }
});
transit.search('西单', '中关村');
</script>
</body>
</html>
